package Form;

import java.awt.Color;
import java.awt.Dimension;
import java.awt.Font;
import java.awt.GridBagConstraints;
import java.awt.GridBagLayout;
import java.awt.Image;
import java.awt.Insets;
import java.awt.Toolkit;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.event.ItemEvent;
import java.awt.event.ItemListener;
import java.awt.event.MouseEvent;
import java.awt.event.MouseListener;

import javax.swing.BorderFactory;
import javax.swing.DefaultComboBoxModel;
import javax.swing.ImageIcon;
import javax.swing.JButton;
import javax.swing.JCheckBox;
import javax.swing.JComboBox;
import javax.swing.JDialog;
import javax.swing.JLabel;
import javax.swing.JOptionPane;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.JSpinner;
import javax.swing.JTextArea;
import javax.swing.JTextField;
import javax.swing.SpinnerNumberModel;
import javax.swing.SwingConstants;
import javax.swing.SwingWorker;

import Control.Shop_Product_Administrate_Controller;
import java.awt.FlowLayout;

@SuppressWarnings("serial")
public class Shop_Product_Administrate_Form extends JPanel {
	
	private JLabel lblAdministrateProducts;
	private JComboBox catalogs;
	private JScrollPane products;
	private JPanel create;
	private JPanel update;
	private JLabel lblId;
	private JLabel lblIdentificationNumber;
	private JButton btnGenerate;
	private JLabel lblDescription;
	private JTextArea description;
	private JScrollPane scrollPaneDesc;
	private JLabel lblImage;
	private JLabel lblName;
	private JTextField txtName;
	private JLabel lblFront;
	private JLabel lblBack;
	
	private JLabel lblFrontimage;
	private JLabel lblBackimage;
	private JButton btnBrowseFront;
	private JButton btnBrowseBack;
	private JLabel lblPrice;
	private JSpinner price;
	private JLabel label;
	private JLabel lblCatalog;
	private JComboBox comboBox;
	private JCheckBox chckbxNewcatalog;
	private JTextField txtCategoryname;
	private JTextArea txtrCategorydesc;
	private JScrollPane scrollPaneCatDesc;
	private JLabel lblCatname;
	private JLabel lblCatdesc;
	private JButton btnCreate;
	private JButton btnReset;
	
	private Main parser;
	private Shop_Product_Administrate_Controller control;
	private JLabel lblId_1;
	private JLabel lblName_1;
	private JTextField txtTextname;
	private JLabel lblDescription_1;
	private JTextArea txtrTxtdescription;
	private JScrollPane scrollPane;
	private JLabel lblFront_1;
	private JLabel lblBack_1;
	private JLabel lblImage_1;
	private JLabel lblFrontimage_1;
	private JLabel lblBackimage_1;
	private JButton btnBrowsefront;
	private JButton btnBrowseback;
	private JLabel label_1;
	private JLabel lblPrice_1;
	private JSpinner price_1;
	private JLabel lblCatalog_1;
	private JComboBox comboBox_1;
	private JCheckBox chckbxNewCatalog_1;
	private JLabel lblName_2;
	private JLabel lblDescription_2;
	private JTextField txtCatname;
	private JScrollPane scrollPane_1;
	private JTextArea txtrCatdesc;
	private JButton btnUpdate;
	private JButton btnReset_1;
	private JPanel productsList;
	private JComboBox statusComboBox;
	private JLabel lblStatus;
	private JButton btnCreateProduct;
	private JDialog createDialog;
	private JLabel lblSkillrequired;
	private JComboBox comboBoxSkill;
	
	public Main getParser() {
		return parser;
	}

	public void setParser(Main parser) {
		this.parser = parser;
	}

	public Shop_Product_Administrate_Controller getControl() {
		return control;
	}

	public void setControl(Shop_Product_Administrate_Controller control) {
		this.control = control;
	}

	public Shop_Product_Administrate_Form(Main parser) {
		setParser(parser);
		setControl(new Shop_Product_Administrate_Controller(this));
		
		GridBagLayout gridBagLayout = new GridBagLayout();
		gridBagLayout.columnWidths = new int[]{112, 0, 95, 0, 0};
		gridBagLayout.rowHeights = new int[] {0, 0, 86, 488, 0};
		gridBagLayout.columnWeights = new double[]{0.0, 0.0, 0.0, 1.0, Double.MIN_VALUE};
		gridBagLayout.rowWeights = new double[]{0.0, 0.0, 0.0, 1.0, Double.MIN_VALUE};
		setLayout(gridBagLayout);
		GridBagConstraints gbc_lblAdministrateProducts = new GridBagConstraints();
		gbc_lblAdministrateProducts.gridwidth = 3;
		gbc_lblAdministrateProducts.anchor = GridBagConstraints.NORTHWEST;
		gbc_lblAdministrateProducts.fill = GridBagConstraints.BOTH;
		gbc_lblAdministrateProducts.insets = new Insets(5, 5, 5, 5);
		gbc_lblAdministrateProducts.gridx = 0;
		gbc_lblAdministrateProducts.gridy = 0;
		add(getLblAdministrateProducts(), gbc_lblAdministrateProducts);
		GridBagConstraints gbc_catalogs = new GridBagConstraints();
		gbc_catalogs.gridwidth = 2;
		gbc_catalogs.fill = GridBagConstraints.HORIZONTAL;
		gbc_catalogs.anchor = GridBagConstraints.WEST;
		gbc_catalogs.insets = new Insets(0, 5, 5, 5);
		gbc_catalogs.gridx = 0;
		gbc_catalogs.gridy = 1;
		add(getCatalogs(), gbc_catalogs);
		GridBagConstraints gbc_btnCreateProduct = new GridBagConstraints();
		gbc_btnCreateProduct.anchor = GridBagConstraints.EAST;
		gbc_btnCreateProduct.insets = new Insets(0, 0, 5, 0);
		gbc_btnCreateProduct.gridx = 3;
		gbc_btnCreateProduct.gridy = 1;
		add(getBtnCreateProduct(), gbc_btnCreateProduct);
		GridBagConstraints gbc_products = new GridBagConstraints();
		gbc_products.insets = new Insets(0, 0, 5, 0);
		gbc_products.gridwidth = 4;
		gbc_products.fill = GridBagConstraints.BOTH;
		gbc_products.gridx = 0;
		gbc_products.gridy = 2;
		add(getProducts(), gbc_products);
		GridBagConstraints gbc_update = new GridBagConstraints();
		gbc_update.gridwidth = 4;
		gbc_update.insets = new Insets(0, 0, 0, 5);
		gbc_update.gridx = 0;
		gbc_update.gridy = 3;
		add(getUpdate(), gbc_update);

		getControl().getProducts(0);
	}

	public JLabel getLblAdministrateProducts() {
		if (lblAdministrateProducts == null) {
			lblAdministrateProducts = new JLabel("Administrate Products");
			lblAdministrateProducts.setFont(new Font("Tahoma", Font.PLAIN, 20));
		}
		return lblAdministrateProducts;
	}
	public JComboBox getCatalogs() {
		if (catalogs == null) {
			catalogs = new JComboBox();
			catalogs.setForeground(Color.BLACK);
			catalogs.setModel(new DefaultComboBoxModel(new String[] {"All"}));
			catalogs.addActionListener(new ActionListener(){

				@Override
				public void actionPerformed(ActionEvent arg0) {
					getControl().getProducts(catalogs.getSelectedIndex());
				}
				
			});
		}
		return catalogs;
	}
	public JScrollPane getProducts() {
		if (products == null) {
			products = new JScrollPane();
			products.setPreferredSize(new Dimension(600, 100));
			products.setViewportView(getProductsList());
		}
		return products;
	}
	public JPanel getCreate() {
		if (create == null) {
			create = new JPanel();
			GridBagLayout gbl_create = new GridBagLayout();
			gbl_create.columnWidths = new int[]{0, 0, 0, 47, 47, 56, 87, 0, 0};
			gbl_create.rowHeights = new int[]{0, 0, 57, 32, 53, 0, 0, 0, 0, 45, 0, 0, 0};
			gbl_create.columnWeights = new double[]{1.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0, Double.MIN_VALUE};
			gbl_create.rowWeights = new double[]{0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0, Double.MIN_VALUE};
			create.setLayout(gbl_create);
			GridBagConstraints gbc_lblId = new GridBagConstraints();
			gbc_lblId.insets = new Insets(5, 5, 5, 5);
			gbc_lblId.anchor = GridBagConstraints.EAST;
			gbc_lblId.gridx = 1;
			gbc_lblId.gridy = 0;
			create.add(getLblId(), gbc_lblId);
			GridBagConstraints gbc_lblIdentificationNumber = new GridBagConstraints();
			gbc_lblIdentificationNumber.fill = GridBagConstraints.BOTH;
			gbc_lblIdentificationNumber.gridwidth = 3;
			gbc_lblIdentificationNumber.anchor = GridBagConstraints.WEST;
			gbc_lblIdentificationNumber.insets = new Insets(5, 0, 5, 5);
			gbc_lblIdentificationNumber.gridx = 2;
			gbc_lblIdentificationNumber.gridy = 0;
			create.add(getLblIdentificationNumber(), gbc_lblIdentificationNumber);
			GridBagConstraints gbc_btnGenerate = new GridBagConstraints();
			gbc_btnGenerate.anchor = GridBagConstraints.NORTHWEST;
			gbc_btnGenerate.insets = new Insets(0, 0, 5, 5);
			gbc_btnGenerate.gridx = 5;
			gbc_btnGenerate.gridy = 0;
			create.add(getBtnGenerate(), gbc_btnGenerate);
			GridBagConstraints gbc_lblName = new GridBagConstraints();
			gbc_lblName.insets = new Insets(0, 5, 5, 5);
			gbc_lblName.anchor = GridBagConstraints.EAST;
			gbc_lblName.gridx = 1;
			gbc_lblName.gridy = 1;
			create.add(getLblName(), gbc_lblName);
			GridBagConstraints gbc_txtName = new GridBagConstraints();
			gbc_txtName.gridwidth = 3;
			gbc_txtName.insets = new Insets(0, 0, 5, 5);
			gbc_txtName.fill = GridBagConstraints.HORIZONTAL;
			gbc_txtName.gridx = 2;
			gbc_txtName.gridy = 1;
			create.add(getTxtName(), gbc_txtName);
			GridBagConstraints gbc_lblDescription = new GridBagConstraints();
			gbc_lblDescription.anchor = GridBagConstraints.NORTHEAST;
			gbc_lblDescription.insets = new Insets(0, 5, 5, 5);
			gbc_lblDescription.gridx = 1;
			gbc_lblDescription.gridy = 2;
			create.add(getLblDescription(), gbc_lblDescription);
			GridBagConstraints gbc_scrollPaneDesc = new GridBagConstraints();
			gbc_scrollPaneDesc.gridwidth = 5;
			gbc_scrollPaneDesc.anchor = GridBagConstraints.NORTH;
			gbc_scrollPaneDesc.fill = GridBagConstraints.BOTH;
			gbc_scrollPaneDesc.insets = new Insets(0, 0, 5, 5);
			gbc_scrollPaneDesc.gridx = 2;
			gbc_scrollPaneDesc.gridy = 2;
			create.add(getScrollPane_1(), gbc_scrollPaneDesc);
			GridBagConstraints gbc_lblFront = new GridBagConstraints();
			gbc_lblFront.gridwidth = 3;
			gbc_lblFront.anchor = GridBagConstraints.SOUTH;
			gbc_lblFront.insets = new Insets(0, 0, 5, 5);
			gbc_lblFront.gridx = 2;
			gbc_lblFront.gridy = 3;
			create.add(getLblFront(), gbc_lblFront);
			GridBagConstraints gbc_lblBack = new GridBagConstraints();
			gbc_lblBack.anchor = GridBagConstraints.SOUTH;
			gbc_lblBack.insets = new Insets(0, 0, 5, 5);
			gbc_lblBack.gridx = 5;
			gbc_lblBack.gridy = 3;
			create.add(getLblBack(), gbc_lblBack);
			GridBagConstraints gbc_lblImage = new GridBagConstraints();
			gbc_lblImage.anchor = GridBagConstraints.NORTHEAST;
			gbc_lblImage.fill = GridBagConstraints.BOTH;
			gbc_lblImage.insets = new Insets(0, 0, 5, 5);
			gbc_lblImage.gridx = 1;
			gbc_lblImage.gridy = 4;
			create.add(getLblImage(), gbc_lblImage);
			GridBagConstraints gbc_lblFrontimage = new GridBagConstraints();
			gbc_lblFrontimage.fill = GridBagConstraints.BOTH;
			gbc_lblFrontimage.gridwidth = 3;
			gbc_lblFrontimage.insets = new Insets(0, 0, 5, 5);
			gbc_lblFrontimage.gridx = 2;
			gbc_lblFrontimage.gridy = 4;
			create.add(getLblFrontimage(), gbc_lblFrontimage);
			GridBagConstraints gbc_lblBackimage = new GridBagConstraints();
			gbc_lblBackimage.fill = GridBagConstraints.BOTH;
			gbc_lblBackimage.insets = new Insets(0, 0, 5, 5);
			gbc_lblBackimage.gridx = 5;
			gbc_lblBackimage.gridy = 4;
			create.add(getLblBackimage(), gbc_lblBackimage);
			GridBagConstraints gbc_btnBrowseFront = new GridBagConstraints();
			gbc_btnBrowseFront.gridwidth = 3;
			gbc_btnBrowseFront.insets = new Insets(0, 0, 5, 5);
			gbc_btnBrowseFront.gridx = 2;
			gbc_btnBrowseFront.gridy = 5;
			create.add(getBtnBrowseFront(), gbc_btnBrowseFront);
			GridBagConstraints gbc_btnBrowseBack = new GridBagConstraints();
			gbc_btnBrowseBack.insets = new Insets(0, 0, 5, 5);
			gbc_btnBrowseBack.gridx = 5;
			gbc_btnBrowseBack.gridy = 5;
			create.add(getBtnBrowseBack(), gbc_btnBrowseBack);
			GridBagConstraints gbc_lblPrice = new GridBagConstraints();
			gbc_lblPrice.anchor = GridBagConstraints.EAST;
			gbc_lblPrice.insets = new Insets(0, 0, 5, 5);
			gbc_lblPrice.gridx = 1;
			gbc_lblPrice.gridy = 6;
			create.add(getLblPrice(), gbc_lblPrice);
			GridBagConstraints gbc_label = new GridBagConstraints();
			gbc_label.anchor = GridBagConstraints.EAST;
			gbc_label.insets = new Insets(0, 0, 5, 5);
			gbc_label.gridx = 2;
			gbc_label.gridy = 6;
			create.add(getLabel(), gbc_label);
			GridBagConstraints gbc_price = new GridBagConstraints();
			gbc_price.gridwidth = 2;
			gbc_price.anchor = GridBagConstraints.WEST;
			gbc_price.insets = new Insets(0, 0, 5, 5);
			gbc_price.gridx = 3;
			gbc_price.gridy = 6;
			create.add(getPrice(), gbc_price);
			GridBagConstraints gbc_lblCatalog = new GridBagConstraints();
			gbc_lblCatalog.anchor = GridBagConstraints.EAST;
			gbc_lblCatalog.insets = new Insets(0, 0, 5, 5);
			gbc_lblCatalog.gridx = 1;
			gbc_lblCatalog.gridy = 7;
			create.add(getLblCatalog(), gbc_lblCatalog);
			GridBagConstraints gbc_comboBox = new GridBagConstraints();
			gbc_comboBox.fill = GridBagConstraints.BOTH;
			gbc_comboBox.gridwidth = 3;
			gbc_comboBox.anchor = GridBagConstraints.WEST;
			gbc_comboBox.insets = new Insets(0, 0, 5, 5);
			gbc_comboBox.gridx = 2;
			gbc_comboBox.gridy = 7;
			create.add(getComboBox(), gbc_comboBox);
			GridBagConstraints gbc_chckbxNewcatalog = new GridBagConstraints();
			gbc_chckbxNewcatalog.insets = new Insets(0, 0, 5, 5);
			gbc_chckbxNewcatalog.gridx = 5;
			gbc_chckbxNewcatalog.gridy = 7;
			create.add(getChckbxNewcatalog(), gbc_chckbxNewcatalog);
			GridBagConstraints gbc_lblCatname = new GridBagConstraints();
			gbc_lblCatname.insets = new Insets(0, 0, 5, 5);
			gbc_lblCatname.anchor = GridBagConstraints.EAST;
			gbc_lblCatname.gridx = 3;
			gbc_lblCatname.gridy = 8;
			create.add(getLblCatname(), gbc_lblCatname);
			GridBagConstraints gbc_txtCategoryname = new GridBagConstraints();
			gbc_txtCategoryname.gridwidth = 2;
			gbc_txtCategoryname.anchor = GridBagConstraints.WEST;
			gbc_txtCategoryname.insets = new Insets(0, 0, 5, 5);
			gbc_txtCategoryname.fill = GridBagConstraints.HORIZONTAL;
			gbc_txtCategoryname.gridx = 4;
			gbc_txtCategoryname.gridy = 8;
			create.add(getTxtCategoryname(), gbc_txtCategoryname);
			GridBagConstraints gbc_lblCatdesc = new GridBagConstraints();
			gbc_lblCatdesc.insets = new Insets(0, 0, 5, 5);
			gbc_lblCatdesc.gridx = 3;
			gbc_lblCatdesc.gridy = 9;
			create.add(getLblCatdesc(), gbc_lblCatdesc);
			GridBagConstraints gbc_scrollPaneCatDesc = new GridBagConstraints();
			gbc_scrollPaneCatDesc.gridwidth = 3;
			gbc_scrollPaneCatDesc.fill = GridBagConstraints.BOTH;
			gbc_scrollPaneCatDesc.insets = new Insets(0, 0, 5, 5);
			gbc_scrollPaneCatDesc.gridx = 4;
			gbc_scrollPaneCatDesc.gridy = 9;
			create.add(getScrollPane_1_1(), gbc_scrollPaneCatDesc);
			GridBagConstraints gbc_btnCreate = new GridBagConstraints();
			gbc_btnCreate.insets = new Insets(0, 0, 5, 5);
			gbc_btnCreate.gridx = 1;
			gbc_btnCreate.gridy = 10;
			create.add(getBtnCreate(), gbc_btnCreate);
			GridBagConstraints gbc_btnReset = new GridBagConstraints();
			gbc_btnReset.insets = new Insets(0, 0, 5, 5);
			gbc_btnReset.gridx = 3;
			gbc_btnReset.gridy = 10;
			create.add(getBtnReset(), gbc_btnReset);
		}
		return create;
	}
	public JPanel getUpdate() {
		if (update == null) {
			update = new JPanel();
			update.setVisible(false);
			GridBagLayout gbl_update = new GridBagLayout();
			gbl_update.columnWidths = new int[] {0, 97, 0, 84, 63, 87, 0, 0, 0};
			gbl_update.rowHeights = new int[] {0, 0, 55, 28, 53, 0, 0, 0, 0, 0, 45, 0, 0};
			gbl_update.columnWeights = new double[]{1.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 1.0, Double.MIN_VALUE};
			gbl_update.rowWeights = new double[]{0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0};
			update.setLayout(gbl_update);
			GridBagConstraints gbc_lblId_1 = new GridBagConstraints();
			gbc_lblId_1.fill = GridBagConstraints.BOTH;
			gbc_lblId_1.anchor = GridBagConstraints.NORTHWEST;
			gbc_lblId_1.insets = new Insets(0, 5, 5, 5);
			gbc_lblId_1.gridx = 1;
			gbc_lblId_1.gridy = 0;
			update.add(getLblId_1(), gbc_lblId_1);
			GridBagConstraints gbc_lblStatus = new GridBagConstraints();
			gbc_lblStatus.insets = new Insets(0, 0, 5, 5);
			gbc_lblStatus.anchor = GridBagConstraints.EAST;
			gbc_lblStatus.gridx = 3;
			gbc_lblStatus.gridy = 0;
			update.add(getLblStatus(), gbc_lblStatus);
			GridBagConstraints gbc_statusComboBox = new GridBagConstraints();
			gbc_statusComboBox.insets = new Insets(0, 0, 5, 5);
			gbc_statusComboBox.fill = GridBagConstraints.HORIZONTAL;
			gbc_statusComboBox.gridx = 4;
			gbc_statusComboBox.gridy = 0;
			update.add(getStatusComboBox(), gbc_statusComboBox);
			GridBagConstraints gbc_lblName_1 = new GridBagConstraints();
			gbc_lblName_1.anchor = GridBagConstraints.EAST;
			gbc_lblName_1.insets = new Insets(0, 0, 5, 5);
			gbc_lblName_1.gridx = 1;
			gbc_lblName_1.gridy = 1;
			update.add(getLblName_1(), gbc_lblName_1);
			GridBagConstraints gbc_txtTextname = new GridBagConstraints();
			gbc_txtTextname.gridwidth = 3;
			gbc_txtTextname.insets = new Insets(0, 0, 5, 5);
			gbc_txtTextname.fill = GridBagConstraints.HORIZONTAL;
			gbc_txtTextname.gridx = 2;
			gbc_txtTextname.gridy = 1;
			update.add(getTxtTextname(), gbc_txtTextname);
			GridBagConstraints gbc_lblDescription_1 = new GridBagConstraints();
			gbc_lblDescription_1.anchor = GridBagConstraints.NORTHEAST;
			gbc_lblDescription_1.insets = new Insets(0, 0, 5, 5);
			gbc_lblDescription_1.gridx = 1;
			gbc_lblDescription_1.gridy = 2;
			update.add(getLblDescription_1(), gbc_lblDescription_1);
			GridBagConstraints gbc_scrollPane = new GridBagConstraints();
			gbc_scrollPane.gridwidth = 5;
			gbc_scrollPane.insets = new Insets(0, 0, 5, 5);
			gbc_scrollPane.fill = GridBagConstraints.BOTH;
			gbc_scrollPane.gridx = 2;
			gbc_scrollPane.gridy = 2;
			update.add(getScrollPane(), gbc_scrollPane);
			GridBagConstraints gbc_lblFront_1 = new GridBagConstraints();
			gbc_lblFront_1.gridwidth = 2;
			gbc_lblFront_1.anchor = GridBagConstraints.SOUTH;
			gbc_lblFront_1.insets = new Insets(0, 0, 5, 5);
			gbc_lblFront_1.gridx = 3;
			gbc_lblFront_1.gridy = 3;
			update.add(getLblFront_1(), gbc_lblFront_1);
			GridBagConstraints gbc_lblBack_1 = new GridBagConstraints();
			gbc_lblBack_1.anchor = GridBagConstraints.SOUTH;
			gbc_lblBack_1.insets = new Insets(0, 0, 5, 5);
			gbc_lblBack_1.gridx = 5;
			gbc_lblBack_1.gridy = 3;
			update.add(getLblBack_1(), gbc_lblBack_1);
			GridBagConstraints gbc_lblImage_1 = new GridBagConstraints();
			gbc_lblImage_1.anchor = GridBagConstraints.EAST;
			gbc_lblImage_1.insets = new Insets(0, 0, 5, 5);
			gbc_lblImage_1.gridx = 1;
			gbc_lblImage_1.gridy = 4;
			update.add(getLblImage_1(), gbc_lblImage_1);
			GridBagConstraints gbc_lblFrontimage_1 = new GridBagConstraints();
			gbc_lblFrontimage_1.gridwidth = 2;
			gbc_lblFrontimage_1.insets = new Insets(0, 0, 5, 5);
			gbc_lblFrontimage_1.gridx = 3;
			gbc_lblFrontimage_1.gridy = 4;
			update.add(getLblFrontimage_1(), gbc_lblFrontimage_1);
			GridBagConstraints gbc_lblBackimage_1 = new GridBagConstraints();
			gbc_lblBackimage_1.insets = new Insets(0, 0, 5, 5);
			gbc_lblBackimage_1.gridx = 5;
			gbc_lblBackimage_1.gridy = 4;
			update.add(getLblBackimage_1(), gbc_lblBackimage_1);
			GridBagConstraints gbc_btnBrowsefront = new GridBagConstraints();
			gbc_btnBrowsefront.gridwidth = 2;
			gbc_btnBrowsefront.insets = new Insets(0, 0, 5, 5);
			gbc_btnBrowsefront.gridx = 3;
			gbc_btnBrowsefront.gridy = 5;
			update.add(getBtnBrowsefront(), gbc_btnBrowsefront);
			GridBagConstraints gbc_btnBrowseback = new GridBagConstraints();
			gbc_btnBrowseback.insets = new Insets(0, 0, 5, 5);
			gbc_btnBrowseback.gridx = 5;
			gbc_btnBrowseback.gridy = 5;
			update.add(getBtnBrowseback(), gbc_btnBrowseback);
			GridBagConstraints gbc_lblPrice_1 = new GridBagConstraints();
			gbc_lblPrice_1.anchor = GridBagConstraints.EAST;
			gbc_lblPrice_1.insets = new Insets(0, 0, 5, 5);
			gbc_lblPrice_1.gridx = 1;
			gbc_lblPrice_1.gridy = 6;
			update.add(getLblPrice_1(), gbc_lblPrice_1);
			GridBagConstraints gbc_label_1 = new GridBagConstraints();
			gbc_label_1.insets = new Insets(0, 0, 5, 5);
			gbc_label_1.gridx = 2;
			gbc_label_1.gridy = 6;
			update.add(getLabel_1(), gbc_label_1);
			GridBagConstraints gbc_price_1 = new GridBagConstraints();
			gbc_price_1.gridwidth = 2;
			gbc_price_1.anchor = GridBagConstraints.WEST;
			gbc_price_1.insets = new Insets(0, 0, 5, 5);
			gbc_price_1.gridx = 3;
			gbc_price_1.gridy = 6;
			update.add(getPrice_1(), gbc_price_1);
			GridBagConstraints gbc_lblSkillrequired = new GridBagConstraints();
			gbc_lblSkillrequired.fill = GridBagConstraints.BOTH;
			gbc_lblSkillrequired.anchor = GridBagConstraints.NORTHWEST;
			gbc_lblSkillrequired.insets = new Insets(0, 0, 5, 5);
			gbc_lblSkillrequired.gridx = 1;
			gbc_lblSkillrequired.gridy = 7;
			update.add(getLblSkillrequired(), gbc_lblSkillrequired);
			GridBagConstraints gbc_comboBoxSkill = new GridBagConstraints();
			gbc_comboBoxSkill.gridwidth = 3;
			gbc_comboBoxSkill.insets = new Insets(0, 0, 5, 5);
			gbc_comboBoxSkill.fill = GridBagConstraints.HORIZONTAL;
			gbc_comboBoxSkill.gridx = 2;
			gbc_comboBoxSkill.gridy = 7;
			update.add(getComboBoxSkill(), gbc_comboBoxSkill);
			GridBagConstraints gbc_lblCatalog_1 = new GridBagConstraints();
			gbc_lblCatalog_1.anchor = GridBagConstraints.EAST;
			gbc_lblCatalog_1.insets = new Insets(0, 0, 5, 5);
			gbc_lblCatalog_1.gridx = 1;
			gbc_lblCatalog_1.gridy = 8;
			update.add(getLblCatalog_1(), gbc_lblCatalog_1);
			GridBagConstraints gbc_comboBox_1 = new GridBagConstraints();
			gbc_comboBox_1.gridwidth = 2;
			gbc_comboBox_1.insets = new Insets(0, 0, 5, 5);
			gbc_comboBox_1.fill = GridBagConstraints.HORIZONTAL;
			gbc_comboBox_1.gridx = 2;
			gbc_comboBox_1.gridy = 8;
			update.add(getComboBox_1(), gbc_comboBox_1);
			GridBagConstraints gbc_chckbxNewCatalog_1 = new GridBagConstraints();
			gbc_chckbxNewCatalog_1.insets = new Insets(0, 0, 5, 5);
			gbc_chckbxNewCatalog_1.gridx = 4;
			gbc_chckbxNewCatalog_1.gridy = 8;
			update.add(getChckbxNewCatalog_1(), gbc_chckbxNewCatalog_1);
			GridBagConstraints gbc_lblName_2 = new GridBagConstraints();
			gbc_lblName_2.anchor = GridBagConstraints.EAST;
			gbc_lblName_2.insets = new Insets(0, 0, 5, 5);
			gbc_lblName_2.gridx = 3;
			gbc_lblName_2.gridy = 9;
			update.add(getLblName_2(), gbc_lblName_2);
			GridBagConstraints gbc_txtCatname = new GridBagConstraints();
			gbc_txtCatname.gridwidth = 2;
			gbc_txtCatname.insets = new Insets(0, 0, 5, 5);
			gbc_txtCatname.fill = GridBagConstraints.HORIZONTAL;
			gbc_txtCatname.gridx = 4;
			gbc_txtCatname.gridy = 9;
			update.add(getTxtCatname(), gbc_txtCatname);
			GridBagConstraints gbc_lblDescription_2 = new GridBagConstraints();
			gbc_lblDescription_2.anchor = GridBagConstraints.NORTHEAST;
			gbc_lblDescription_2.insets = new Insets(0, 0, 5, 5);
			gbc_lblDescription_2.gridx = 3;
			gbc_lblDescription_2.gridy = 10;
			update.add(getLblDescription_2(), gbc_lblDescription_2);
			GridBagConstraints gbc_scrollPane_1 = new GridBagConstraints();
			gbc_scrollPane_1.gridwidth = 3;
			gbc_scrollPane_1.insets = new Insets(0, 0, 5, 5);
			gbc_scrollPane_1.fill = GridBagConstraints.BOTH;
			gbc_scrollPane_1.gridx = 4;
			gbc_scrollPane_1.gridy = 10;
			update.add(getScrollPane_1_2(), gbc_scrollPane_1);
			GridBagConstraints gbc_btnUpdate = new GridBagConstraints();
			gbc_btnUpdate.anchor = GridBagConstraints.NORTH;
			gbc_btnUpdate.insets = new Insets(0, 0, 5, 5);
			gbc_btnUpdate.gridx = 1;
			gbc_btnUpdate.gridy = 11;
			update.add(getBtnUpdate(), gbc_btnUpdate);
			GridBagConstraints gbc_btnReset_1 = new GridBagConstraints();
			gbc_btnReset_1.anchor = GridBagConstraints.NORTH;
			gbc_btnReset_1.insets = new Insets(0, 0, 5, 5);
			gbc_btnReset_1.gridx = 3;
			gbc_btnReset_1.gridy = 11;
			update.add(getBtnReset_1(), gbc_btnReset_1);
		}
		return update;
	}
	public JLabel getLblId() {
		if (lblId == null) {
			lblId = new JLabel("Id:");
			getControl().generateProductId();
		}
		return lblId;
	}
	public JLabel getLblIdentificationNumber() {
		if (lblIdentificationNumber == null) {
			lblIdentificationNumber = new JLabel("");
			lblIdentificationNumber.setHorizontalAlignment(SwingConstants.CENTER);
			lblIdentificationNumber.setBorder(BorderFactory.createLineBorder(Color.GRAY, 1));
		}
		return lblIdentificationNumber;
	}
	public JButton getBtnGenerate() {
		if (btnGenerate == null) {
			btnGenerate = new JButton("Generate");
			btnGenerate.addMouseListener(new MouseListener(){

				@Override
				public void mouseClicked(MouseEvent arg0) {
					getControl().generateProductId();
				}

				@Override
				public void mouseEntered(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mouseExited(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mousePressed(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mouseReleased(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}
				
			});
		}
		return btnGenerate;
	}
	public JLabel getLblDescription() {
		if (lblDescription == null) {
			lblDescription = new JLabel("Description:");
			lblDescription.setLabelFor(getDescription());
		}
		return lblDescription;
	}
	public JTextArea getDescription() {
		if (description == null) {
			description = new JTextArea();
			description.setLineWrap(true);
		}
		return description;
	}
	public JScrollPane getScrollPane_1() {
		if (scrollPaneDesc == null) {
			scrollPaneDesc = new JScrollPane();
			scrollPaneDesc.setViewportView(getDescription());
		}
		return scrollPaneDesc;
	}
	public JLabel getLblImage() {
		if (lblImage == null) {
			lblImage = new JLabel("Images:");
			lblImage.setHorizontalAlignment(SwingConstants.RIGHT);
		}
		return lblImage;
	}
	public JLabel getLblName() {
		if (lblName == null) {
			lblName = new JLabel("Name:");
			lblName.setLabelFor(getTxtName());
		}
		return lblName;
	}
	public JTextField getTxtName() {
		if (txtName == null) {
			txtName = new JTextField();
			txtName.setBorder(BorderFactory.createLineBorder(Color.GRAY, 1));
			txtName.setText("");
			txtName.setColumns(10);
		}
		return txtName;
	}
	public JLabel getLblFront() {
		if (lblFront == null) {
			lblFront = new JLabel("Front");
		}
		return lblFront;
	}
	public JLabel getLblBack() {
		if (lblBack == null) {
			lblBack = new JLabel("Back");
		}
		return lblBack;
	}
	public JLabel getLblFrontimage() {
		if (lblFrontimage == null) {
			lblFrontimage = new JLabel("");
			lblFrontimage.setHorizontalAlignment(SwingConstants.CENTER);
			lblFrontimage.setIcon(new ImageIcon(Toolkit.getDefaultToolkit().createImage("Resources/Images/Default/no_image.jpg").getScaledInstance(70, 70, Image.SCALE_DEFAULT)));
		}
		return lblFrontimage;
	}
	public JLabel getLblBackimage() {
		if (lblBackimage == null) {
			lblBackimage = new JLabel("");
			lblBackimage.setHorizontalAlignment(SwingConstants.CENTER);
			lblBackimage.setIcon(new ImageIcon(Toolkit.getDefaultToolkit().createImage("Resources/Images/Default/no_image.jpg").getScaledInstance(70, 70, Image.SCALE_DEFAULT)));
		}
		return lblBackimage;
	}
	public JButton getBtnBrowseFront() {
		if (btnBrowseFront == null) {
			btnBrowseFront = new JButton("Browse");
			btnBrowseFront.addActionListener(new ActionListener() {
				public void actionPerformed(ActionEvent arg0) {
					getControl().setFrontImageUrl();
				}
			});
		}
		return btnBrowseFront;
	}
	public JButton getBtnBrowseBack() {
		if (btnBrowseBack == null) {
			btnBrowseBack = new JButton("Browse");
			btnBrowseBack.addActionListener(new ActionListener() {
				public void actionPerformed(ActionEvent arg0) {
					getControl().setBackImageUrl();
				}
			});
		}
		return btnBrowseBack;
	}
	public JLabel getLblPrice() {
		if (lblPrice == null) {
			lblPrice = new JLabel("Price:");
		}
		return lblPrice;
	}
	public JSpinner getPrice() {
		if (price == null) {
			price = new JSpinner();
			price.setModel(new SpinnerNumberModel(20.0, 10.0, 100.0, 5.0));
			price.setValue(25);
		}
		return price;
	}
	public JLabel getLabel() {
		if (label == null) {
			label = new JLabel("$");
		}
		return label;
	}
	public JLabel getLblCatalog() {
		if (lblCatalog == null) {
			lblCatalog = new JLabel("Catalog:");
		}
		return lblCatalog;
	}
	public JComboBox getComboBox() {
		if (comboBox == null) {
			comboBox = new JComboBox();
			comboBox.setForeground(Color.BLACK);
			comboBox.setModel(new DefaultComboBoxModel(new String[] {"Select a catalog.."}));
			getControl().setCatalogs();
			comboBox.addItemListener(new ItemListener(){

				@Override
				public void itemStateChanged(ItemEvent arg0) {
					if(getComboBox().getSelectedIndex() > 0){
						getControl().changeCatalogDetails();
					}
					else{
						getTxtCategoryname().setText("");
						getTxtrCategorydesc().setText("");
					}
				}
				
			});
		}
		return comboBox;
	}
	public JCheckBox getChckbxNewcatalog() {
		if (chckbxNewcatalog == null) {
			chckbxNewcatalog = new JCheckBox("New Catalog");
			chckbxNewcatalog.addMouseListener(new MouseListener(){

				@Override
				public void mouseClicked(MouseEvent arg0) {
					if(chckbxNewcatalog.isSelected()){
						getComboBox().setEnabled(false);
						getTxtCategoryname().setEnabled(true);
						getTxtrCategorydesc().setEnabled(true);
						getTxtCategoryname().setText("");
						getTxtrCategorydesc().setText("");
					}
					else{
						getComboBox().setEnabled(true);
						getTxtCategoryname().setEnabled(false);
						getTxtrCategorydesc().setEnabled(false);
						if(getComboBox().getSelectedIndex() > 0){
							getControl().changeCatalogDetails();
						}
						else{
							getTxtCategoryname().setText("");
							getTxtrCategorydesc().setText("");
						}
					}
				}

				@Override
				public void mouseEntered(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mouseExited(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mousePressed(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mouseReleased(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}
				
			});
		}
		return chckbxNewcatalog;
	}
	public JTextField getTxtCategoryname() {
		if (txtCategoryname == null) {
			txtCategoryname = new JTextField();
			txtCategoryname.setEnabled(false);
			txtCategoryname.setBorder(BorderFactory.createLineBorder(Color.GRAY, 1));
			txtCategoryname.setColumns(10);
		}
		return txtCategoryname;
	}
	public JTextArea getTxtrCategorydesc() {
		if (txtrCategorydesc == null) {
			txtrCategorydesc = new JTextArea();
			txtrCategorydesc.setEnabled(false);
			txtrCategorydesc.setLineWrap(true);
		}
		return txtrCategorydesc;
	}
	public JScrollPane getScrollPane_1_1() {
		if (scrollPaneCatDesc == null) {
			scrollPaneCatDesc = new JScrollPane();
			scrollPaneCatDesc.setViewportView(getTxtrCategorydesc());
		}
		return scrollPaneCatDesc;
	}
	public JLabel getLblCatname() {
		if (lblCatname == null) {
			lblCatname = new JLabel("Name:");
		}
		return lblCatname;
	}
	public JLabel getLblCatdesc() {
		if (lblCatdesc == null) {
			lblCatdesc = new JLabel("Description:");
		}
		return lblCatdesc;
	}
	public JButton getBtnCreate() {
		if (btnCreate == null) {
			btnCreate = new JButton("Create");
			btnCreate.addActionListener(new ActionListener(){

				@Override
				public void actionPerformed(ActionEvent arg0) {
					int response = JOptionPane.showConfirmDialog(null, "Proceed with product creation?", "Confirm Creation", JOptionPane.YES_NO_OPTION);
					if(response == JOptionPane.YES_OPTION){
						SwingWorker<Void, Void> worker = new SwingWorker<Void, Void>(){

							@Override
							protected Void doInBackground() throws Exception {
								getControl().saveProduct();
								return null;
							}
							
							protected void done(){
								parser.closeProgressBar();
							}
							
						};
						parser.getProgressBar();
						worker.execute();
					}
				}
				
			});
		}
		return btnCreate;
	}
	public JButton getBtnReset() {
		if (btnReset == null) {
			btnReset = new JButton("Reset");
			btnReset.addActionListener(new ActionListener(){

				@Override
				public void actionPerformed(ActionEvent arg0) {
					getControl().reset();
				}
				
			});
		}
		return btnReset;
	}
	public JLabel getLblId_1() {
		if (lblId_1 == null) {
			lblId_1 = new JLabel("Id");
			lblId_1.setFont(new Font("Tahoma", Font.PLAIN, 20));
		}
		return lblId_1;
	}
	public JLabel getLblName_1() {
		if (lblName_1 == null) {
			lblName_1 = new JLabel("Name:");
		}
		return lblName_1;
	}
	public JTextField getTxtTextname() {
		if (txtTextname == null) {
			txtTextname = new JTextField();
			txtTextname.setBorder(BorderFactory.createLineBorder(Color.GRAY, 1));
			txtTextname.setColumns(10);
		}
		return txtTextname;
	}
	public JLabel getLblDescription_1() {
		if (lblDescription_1 == null) {
			lblDescription_1 = new JLabel("Description:");
		}
		return lblDescription_1;
	}
	public JTextArea getTxtrTxtdescription() {
		if (txtrTxtdescription == null) {
			txtrTxtdescription = new JTextArea();
			txtrTxtdescription.setLineWrap(true);
		}
		return txtrTxtdescription;
	}
	public JScrollPane getScrollPane() {
		if (scrollPane == null) {
			scrollPane = new JScrollPane();
			scrollPane.setViewportView(getTxtrTxtdescription());
		}
		return scrollPane;
	}
	public JLabel getLblFront_1() {
		if (lblFront_1 == null) {
			lblFront_1 = new JLabel("Front");
		}
		return lblFront_1;
	}
	public JLabel getLblBack_1() {
		if (lblBack_1 == null) {
			lblBack_1 = new JLabel("Back");
		}
		return lblBack_1;
	}
	public JLabel getLblImage_1() {
		if (lblImage_1 == null) {
			lblImage_1 = new JLabel("Images:");
		}
		return lblImage_1;
	}
	public JLabel getLblFrontimage_1() {
		if (lblFrontimage_1 == null) {
			lblFrontimage_1 = new JLabel("");
			lblFrontimage_1.setHorizontalAlignment(SwingConstants.CENTER);
			lblFrontimage_1.addMouseListener(new MouseListener(){

				@Override
				public void mouseClicked(MouseEvent arg0) {
					getControl().setUpdatefrontImageUrl();
				}

				@Override
				public void mouseEntered(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mouseExited(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mousePressed(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mouseReleased(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}
				
			});
		}
		return lblFrontimage_1;
	}
	public JLabel getLblBackimage_1() {
		if (lblBackimage_1 == null) {
			lblBackimage_1 = new JLabel("");
			lblBackimage_1.setHorizontalAlignment(SwingConstants.CENTER);
			lblBackimage_1.addMouseListener(new MouseListener(){

				@Override
				public void mouseClicked(MouseEvent e) {
					getControl().setUpdatebackImageUrl();
				}

				@Override
				public void mouseEntered(MouseEvent e) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mouseExited(MouseEvent e) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mousePressed(MouseEvent e) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mouseReleased(MouseEvent e) {
					// TODO Auto-generated method stub
					
				}
				
			});
		}
		return lblBackimage_1;
	}
	public JButton getBtnBrowsefront() {
		if (btnBrowsefront == null) {
			btnBrowsefront = new JButton("Browse");
			btnBrowsefront.addActionListener(new ActionListener(){

				@Override
				public void actionPerformed(ActionEvent e) {
					getControl().setUpdatefrontImageUrl();
				}
				
			});
		}
		return btnBrowsefront;
	}
	public JButton getBtnBrowseback() {
		if (btnBrowseback == null) {
			btnBrowseback = new JButton("Browse");
			btnBrowseback.addActionListener(new ActionListener(){

				@Override
				public void actionPerformed(ActionEvent e) {
					getControl().setUpdatebackImageUrl();
				}
			
			});
		}
		return btnBrowseback;
	}
	public JLabel getLabel_1() {
		if (label_1 == null) {
			label_1 = new JLabel("$");
		}
		return label_1;
	}
	public JLabel getLblPrice_1() {
		if (lblPrice_1 == null) {
			lblPrice_1 = new JLabel("Price:");
		}
		return lblPrice_1;
	}
	public JSpinner getPrice_1() {
		if (price_1 == null) {
			price_1 = new JSpinner();
			price_1.setModel(new SpinnerNumberModel(20.0, 10.0, 100.0, 5.0));
		}
		return price_1;
	}
	public JLabel getLblCatalog_1() {
		if (lblCatalog_1 == null) {
			lblCatalog_1 = new JLabel("Catalog:");
		}
		return lblCatalog_1;
	}
	public JComboBox getComboBox_1() {
		if (comboBox_1 == null) {
			comboBox_1 = new JComboBox();
			comboBox_1.setForeground(Color.BLACK);
			comboBox_1.addActionListener(new ActionListener(){

				@Override
				public void actionPerformed(ActionEvent arg0) {
					getControl().changeUpdateCatalogDetails();
				}
				
			});
		}
		return comboBox_1;
	}
	public JCheckBox getChckbxNewCatalog_1() {
		if (chckbxNewCatalog_1 == null) {
			chckbxNewCatalog_1 = new JCheckBox("New Catalog");
			chckbxNewCatalog_1.addMouseListener(new MouseListener(){

				@Override
				public void mouseClicked(MouseEvent e) {
					if(chckbxNewCatalog_1.isSelected()){
						getComboBox_1().setEnabled(false);
						getTxtCatname().setEditable(true);
						getTxtrCatdesc().setEditable(true);
						getTxtCatname().setText("");
						getTxtrCatdesc().setText("");
					}
					else{
						getComboBox_1().setEnabled(true);
						getTxtCatname().setEditable(false);
						getTxtrCatdesc().setEditable(false);
						if(getComboBox_1().getSelectedIndex() > 0){
							getControl().changeUpdateCatalogDetails();
						}
						else{
							getTxtCatname().setText("");
							getTxtrCatdesc().setText("");
						}
					}
				}

				@Override
				public void mouseEntered(MouseEvent e) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mouseExited(MouseEvent e) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mousePressed(MouseEvent e) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mouseReleased(MouseEvent e) {
					// TODO Auto-generated method stub
					
				}
				
			});
		}
		return chckbxNewCatalog_1;
	}
	public JLabel getLblName_2() {
		if (lblName_2 == null) {
			lblName_2 = new JLabel("Name:");
		}
		return lblName_2;
	}
	public JLabel getLblDescription_2() {
		if (lblDescription_2 == null) {
			lblDescription_2 = new JLabel("Description:");
		}
		return lblDescription_2;
	}
	public JTextField getTxtCatname() {
		if (txtCatname == null) {
			txtCatname = new JTextField();
			txtCatname.setEditable(false);
			txtCatname.setBorder(BorderFactory.createLineBorder(Color.GRAY, 1));
			txtCatname.setColumns(10);
		}
		return txtCatname;
	}
	public JScrollPane getScrollPane_1_2() {
		if (scrollPane_1 == null) {
			scrollPane_1 = new JScrollPane();
			scrollPane_1.setViewportView(getTxtrCatdesc());
		}
		return scrollPane_1;
	}
	public JTextArea getTxtrCatdesc() {
		if (txtrCatdesc == null) {
			txtrCatdesc = new JTextArea();
			txtrCatdesc.setLineWrap(true);
			txtrCatdesc.setEditable(false);
		}
		return txtrCatdesc;
	}
	public JButton getBtnUpdate() {
		if (btnUpdate == null) {
			btnUpdate = new JButton("Update");
			btnUpdate.addMouseListener(new MouseListener(){

				@Override
				public void mouseClicked(MouseEvent arg0) {
					int response = JOptionPane.showConfirmDialog(null, "Proceed with product update?\nChanges cannot be undone once confirmed.", "Confirm customization", JOptionPane.YES_NO_OPTION);
					if(response == JOptionPane.YES_OPTION){
						SwingWorker<Void, Void> worker = new SwingWorker<Void, Void>(){

							@Override
							protected Void doInBackground() throws Exception {
								getControl().updateProduct();
								return null;
							}
							
							protected void done(){
								parser.closeProgressBar();
							}
							
						};
						parser.getProgressBar();
						worker.execute();
					}
				}

				@Override
				public void mouseEntered(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mouseExited(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mousePressed(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mouseReleased(MouseEvent arg0) {
					// TODO Auto-generated method stub
					
				}
				
			});
		}
		return btnUpdate;
	}
	public JButton getBtnReset_1() {
		if (btnReset_1 == null) {
			btnReset_1 = new JButton("Reset");
			btnReset_1.addMouseListener(new MouseListener(){

				@Override
				public void mouseClicked(MouseEvent e) {
					getControl().resetDefault();
				}

				@Override
				public void mouseEntered(MouseEvent e) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mouseExited(MouseEvent e) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mousePressed(MouseEvent e) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void mouseReleased(MouseEvent e) {
					// TODO Auto-generated method stub
					
				}
				
			});
		}
		return btnReset_1;
	}
	public JPanel getProductsList() {
		if (productsList == null) {
			productsList = new JPanel();
			FlowLayout flowLayout = (FlowLayout) productsList.getLayout();
			flowLayout.setAlignment(FlowLayout.LEFT);
		}
		return productsList;
	}
	public JComboBox getStatusComboBox() {
		if (statusComboBox == null) {
			statusComboBox = new JComboBox();
			statusComboBox.setForeground(Color.BLACK);
			statusComboBox.setModel(new DefaultComboBoxModel(new String[] {"Available", "Unavailable"}));
		}
		return statusComboBox;
	}
	public JLabel getLblStatus() {
		if (lblStatus == null) {
			lblStatus = new JLabel("Status:");
		}
		return lblStatus;
	}
	public JButton getBtnCreateProduct() {
		if (btnCreateProduct == null) {
			btnCreateProduct = new JButton("Create Product");
			btnCreateProduct.addActionListener(new ActionListener(){

				@Override
				public void actionPerformed(ActionEvent arg0) {
					createDialog = new JDialog(getParser());
					createDialog.getContentPane().add(getCreate());
					createDialog.pack();
					createDialog.setLocationRelativeTo(getParser());
					createDialog.setVisible(true);
				}
				
			});
		}
		return btnCreateProduct;
	}
	public JDialog getCreateDialog(){
		return createDialog;
	}
	public JLabel getLblSkillrequired() {
		if (lblSkillrequired == null) {
			lblSkillrequired = new JLabel("Skill (Required):");
			lblSkillrequired.setHorizontalAlignment(SwingConstants.RIGHT);
		}
		return lblSkillrequired;
	}
	public JComboBox getComboBoxSkill() {
		if (comboBoxSkill == null) {
			comboBoxSkill = new JComboBox();
			comboBoxSkill.setForeground(Color.BLACK);
		}
		return comboBoxSkill;
	}
}
